<?php
defined('BASEPATH') OR exit('No direct script access allowed');
?>
    <div class="main">
        <div class="sidebar">
            <div class="menu_wrap">
                <!--menu-->
                <div class="menu">
                    <div class="menu_title"><?php echo $category[0][0][lang('field_category_title')];?></div>
                    <ul>
                    <?php if (isset($category[$category[0][0]['id']])){ foreach ($category[$category[0][0]['id']] as $m){?>
                        <li <?php echo $m['id']==$menu_selected?'class="selected"':'';?>>
                        <a href="<?php echo site_url($m['list_uri'].'/'.$m['id']);?>"><?php echo $m[lang('field_category_title')];?></a>
                        </li>             
                    <?php }}?>
                    </ul>
                </div>
            </div>
            <div class="contact_wrap">
                <div class="contact">
                <!--side contact start-->
                <?php echo ${lang('field_side_contact')};?>
                <!--side contact end-->
                </div>
            </div>
        </div>
        <div class="mainbody">
            <div class="title_wrap">
                <!--title-->
                <div class="sitemap">
                <?php echo lang('page_location');?>：
                <?php foreach ($location as $l){?>
                    <?php if($l['link']){?>
                    <span><?php echo $l['link'];?></span>
                    <?php }?>
                    <?php if($l['url']){?>
                    <a href="<?php echo site_url($l['url']);?>"><?php echo $l['title'];?></a>
                    <?php }else {?>
                    <span><?php echo $l['title'];?></span>
                    <?php }?>
                <?php }?>
                </div>
            </div>
            <div class="content_wrap">
                <!--content-->
                <div class="news_list">
                    <ul>
                    <?php foreach ($list as $news){?>
                    <li><a href="<?php echo site_url($news['uri'].'/'.$news['id']);?>"><?php echo $news[lang('field_content_title')];?></a><span><?php echo date('m/d',$news['add_time']);?></span></li>
                    <?php }?>
                    </ul>
                    <?php echo empty($list)?lang('page_list_empty'):'';?>
                    <div style="padding:10px 0px; text-align:right; height:24px;">
                    <?php echo $pager;?>
                    </div>
                </div>
                <!--content-->    
            </div>    
        </div>
        <div class="clearFloat"></div>
    </div>